<!DOCTYPE html>
<html lang="en">

<head>
	<meta charset="UTF-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<title>Document</title>
	<!-- 外部样式文件,href可以是本地文件路径,也可以是网络上的路径 -->
	<link rel="stylesheet" href="font.css">
	<style>
		body {
			perspective: 1000px;
		}

		section {
			width: 300px;
			height: 300px;
			margin: 100px auto;
			background: url(image/img-1.jpg) no-repeat;
			background-size: cover;
			position: relative;
			/* 让父盒子粒度子盒子以3D效果显示 */
			transform-style: preserve-3d;
			/* 匀速动画 */
			transition: all 5s linear;
		}

		section:hover{
			transform: rotateY(360deg);
		}

		section div {
			width: 100%;
			height: 100%;
			background: url(image/dog.gif) no-repeat;
			background-size: cover;
			position: absolute;
			top: 0;
			left: 0;
		}

		section div:nth-child(1) {
			transform: rotateY(0deg) translateZ(400px);
		}

		section div:nth-child(2) {
			transform: rotateY(60deg) translateZ(400px);
		}

		section div:nth-child(3) {
			transform: rotateY(120deg) translateZ(400px);
		}

		section div:nth-child(4) {
			transform: rotateY(180deg) translateZ(400px);
		}

		section div:nth-child(5) {
			transform: rotateY(240deg) translateZ(400px);
		}

		section div:nth-child(6) {
			transform: rotateY(300deg) translateZ(400px);
		}
	</style>
</head>

<body style="height: 100%;width: 100%;">
	<section>
		<div></div>
		<div></div>
		<div></div>
		<div></div>
		<div></div>
		<div></div>
	</section>
</body>

</html>